package com.itheima.Controller;

import com.itheima.domain.Orders;
import com.itheima.service.OrdersService;
import com.itheima.service.impl.OrdersServiceImpl;
import org.junit.Test;

import java.util.List;

public class OredersController {
    private  OrdersService ordersService = new OrdersServiceImpl();
    @Test
    public  void findAll1() {
        List<Orders> list = ordersService.findAll();
        for (Orders orders : list) {
            System.out.println("订单编号"+orders.getNumber()+"----用户名称"+orders.getUser().getUsername());
        }
    }
}
